# the minimum version of CMake.
cmake_minimum_required(VERSION 3.5.0)
project(AKI_native_demo)

set(NATIVERENDER_ROOT_PATH ${CMAKE_CURRENT_SOURCE_DIR})

if(DEFINED PACKAGE_FIND_FILE)
    include(${PACKAGE_FIND_FILE})
endif()

include_directories(${NATIVERENDER_ROOT_PATH}
                    ${NATIVERENDER_ROOT_PATH}/include)

# 添加一个共享库（动态库）目标，名为entry，源文件为entry.cpp，最终生成的动态库为libentry.so，lib为前缀、.so为后缀
add_library(entry SHARED entry.cpp)

# 添加aki子目录，会加载aki目录下的CMakeLists.txt，注意：add_subdirectory只能一个一个的添加
add_subdirectory(aki)
add_subdirectory(hello)
# 链接aki_jsbind目标库，aki/src/CMakeLists.txt对应编译的目标库名称
target_link_libraries(entry PUBLIC aki_jsbind)

